<%= form_for @order_made_payment,
     :url => create_payment_order_url,
     :remote => true,
     :method => :post do |f|
 %>
<h6><b>新增-订做付款</b></h6>
<%= f.hidden_field :order_item_id %>
<dl>
  <dt>
    订做记录
  </dt>
  <dd>
    <%= f.select :order_made_id, @order_mades.collect {|order_made| [ "\"#{order_made.order_made_on}\"向『#{order_made.factory_name}』订做【#{order_made.order_made_count}】件", order_made.id ] }, {},:id => "order_item_#{@order_made_payment.order_item_id}_order_payment_id" %>
  </dd>
</dl>
<dl>
  <dt>
    付款日期
  </dt>
  <dd>
    <%= f.text_field :payed_on, :class => :date %>
    <script>
      $('#order_made_payment_payed_on').datepicker({
        showButtonPanel: true
      });
    </script>
  </dd>
</dl>
<dl>
  <dt>
    金额
  </dt>
  <dd>
    <%= f.text_field :how_much, :value => '0.00' %>
  </dd>
</dl>
<dl>
  <dt>
    备注
  </dt>
  <dd>
    <%= f.text_area :remark, :rows => 5%>
  </dd>
</dl>
<dl>
  <dd class="form_tool">
    <%= f.submit '保存' %>
    <%= link_to '返回', new_feed_order_url(@order_made_payment.order_item),:remote => true, :method => :get, :id => "new_payment_btn#{@order_made_payment.order_item.id}", :class => 'button' %>
  </dd>
</dl>
<div class="clear"></div>
<%end%>
